/*
 * @Author: 高瑞寒 15932717091@163.com
 * @Date: 2022-04-28 14:12:06
 * @LastEditTime: 2022-04-28 14:40:52
 * @LastEditors: 高瑞寒 15932717091@163.com
 * @Description: 
 */
import axios from 'axios'
import React, { Component } from 'react'

export default class App extends Component {
  sendAjax1 = async () => {
  const res=  await axios.get('http://localhost:3000/api1/students')
  console.log(res);
  }
  sendAjax2 = async () => {
    const res = await axios.get('http://localhost:3000/api2/cars')
    console.log(res);
  }
  render() {
    return (
      <div>
        <button onClick={this.sendAjax1}>发送请求5000</button>
        <button onClick={this.sendAjax2}>发送请求5001</button>
      </div>
    )
  }
}
